package me.zhengjie.vo;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import me.zhengjie.tool.NPETool;

import java.io.Serializable;

/**
 * 期号时间段
 */
@ApiModel("Period")
public class Period implements Serializable {
    private static final long serialVersionUID = -5798801665136370212L;
    @ApiModelProperty("开始期号")
    private Integer aae041; //开始期号
    @ApiModelProperty("结束期号")
    private Integer aae042; //结束期号

    public Period(Integer aae041, Integer aae042) {
        NPETool.isEmptyThrowException(aae041, "开始期号");
        NPETool.isEmptyThrowException(aae042, "结束期号");
        if (aae041 > aae042) {
            throw new IllegalArgumentException("开始期号" + aae041.toString() + "不能晚于" + aae042.toString());
        }
        this.aae041 = aae041;
        this.aae042 = aae042;
    }

    public Integer getAae041() {
        return aae041;
    }

    public void setAae041(Integer aae041) {
        this.aae041 = aae041;
    }

    public Integer getAae042() {
        return aae042;
    }

    public void setAae042(Integer aae042) {
        this.aae042 = aae042;
    }
}
